package com.topisv.tms.service.vo;

import java.math.BigDecimal;


public class AllRankList implements Comparable<AllRankList> {

	private String jobuuid;
	public String getJobuuid() {
		return jobuuid;
	}

	public void setJobuuid(String jobuuid) {
		this.jobuuid = jobuuid;
	}

	private String realName;// 操作人
	private int orderNumber;// 订单数量
	private long allWorkTypeTime;// 作业总时间
	private double time;//每单平均时间
	private String lineType;//流水类型
	
	public String getLineType() {
		return lineType;
	}

	public void setLineType(String lineType) {
		this.lineType = lineType;
	}

	private String workType;//作业类型

	public String getWorkType() {
		return workType;
	}

	public void setWorkType(String workType) {
		this.workType = workType;
	}

	public String getRealName() {
		return realName;
	}

	public void setRealName(String realName) {
		this.realName = realName;
	}

	public int getOrderNumber() {
		return orderNumber;
	}

	public void setOrderNumber(int orderNumber) {
		this.orderNumber = orderNumber;
	}

	public long getAllWorkTypeTime() {
		return allWorkTypeTime;
	}

	public void setAllWorkTypeTime(long allWorkTypeTime) {
		this.allWorkTypeTime = allWorkTypeTime;
	}

	public double getTime() {
		time = allWorkTypeTime/1000 / orderNumber;
		BigDecimal b = new BigDecimal(time);
		time = b.setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue();
		return time;
	}

	public void setTime(double time) {
		this.time = time;
	}

	@Override
	public int compareTo(AllRankList o) {
		// TODO Auto-generated method stub
		return (o.getTime() - this.getTime()) > 0 ? -1 : 1;
	}

}
